//-------------------------------------------------------------
//
//  PokerTexasHoldem.h
//  CPokerTexasHoldem: Main class of poker texas holde'm game
//
//  Created by Enric Vergara on 20.10.12. 
//  Copyright OWLAB 2010. All rights reserved.
//-------------------------------------------------------------


//---- Imports-----
#import "PokerTexasHoldem_def.h"
#import "cocos2d.h"
#import "Card.h"
#import "Board.h"
#import "Deck.h"
#import "Player.h"
#import "ConditionGame.h"
#import "ExitMenu.h"
//-----------------


// PokerTexasHoldem Layer
@interface CPokerTexasHoldem : CCLayer
{
    
@public
    
@private
    
    CBoard              * m_pBoard;
    CDeck               * m_pDeck;
    unsigned int        m_uiBank;
    CCLabel             * m_sBankLabel;
    bool                m_bFirstRound;
    bool                m_bFirstBet;
    CConditionGame*     m_ConditionGame;
    unsigned int        m_uiCurrentBet;
    CCLabel             * m_sCurrentBetLabel;
    PTH_STATE_MACHINE   m_StateMachine;
    
    
    //--GUI per Menus: Exit,newHand?-----
    CCMenu              * m_MenuNewHand;
    CCMenuItemFont      * m_Button_NewHand;
    bool                m_bButtonPressed_NewHand;
    CExitMenu           * m_ExitMenu;
    //-----------------------------------
    
    
    //-----Player Information-------------
    unsigned int        m_uiNumplayers;
    CPlayer*            m_Players[NUM_PLAYERS_MAX];
    float               m_Players_Orientations[NUM_PLAYERS_MAX];
    CGPoint             m_Players_Positions[NUM_PLAYERS_MAX];
    //-------------------------------------
    
}


+(id)           scene;                  
-(void)         update:(ccTime)delta;   
-(void)         addPlayer:(TYPE_POKER_PLAYER)typePlayer Name:(NSString *) theName;
-(void)         initPosPlayers;
-(void)         whoWins;
-(unsigned int) getBank;
-(void)         setBank:(unsigned int) bank;
-(void)         setCurrentBet:(unsigned int) currentBet;
-(void)         changeState:(TYPE_POKER_STATE) state;
-(void)         betNextPlayer;
-(int)          findDelear;
-(int)          findSmallBlind;
-(int)          findBigBlind;
-(void)         menuNewHandTouched: (id) sender;
-(void)         setPlayerButtons;
-(void)         moveDelearAndBlind_Buttons;
-(void)         changePlayerType:(unsigned int) playerId TypeOfPlayer:(TYPE_PLAYER) type;
@end
